<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta http-equiv="X-UA-Compatible" content="ie=edge">
    <title>Document</title>
</head>
<body>
    <script>
       
       var  num1=prompt("请输入第一个数：");
       var  num2=prompt("请输入第2个数：");
       var  num3=prompt("请输入4则运算：1.+2.-3.*4./");
       if(num=1){
           alert(parseInt(num1)+parseInt(num2));
       }

  else if(num=2){
    alert(parseInt(num1)-parseInt(num2));

       }
     

  else   if(num=3){
    alert(parseInt(num1)*parseInt(num2));
       }
     else  if(num=4){
        alert(parseInt(num1)/parseInt(num2));
       }

    
    
    
    
    
    </script>

    
</body>
</html>